
<template tag="以下文档内容为hycli自动生成">
  <div>
    <el-dialog
      v-model="conf.acp_visible"
      title="待复评"
      :close-on-click-modal="false"
      width="60%"
      draggable
      :before-close="hide_acp"
    >
      <el-form
        :model="form_acp"
        
        ref="fm_acp"
        :rules="rules_acp"
      >
  <el-row>
</el-row>
      </el-form>
      <template #footer>
        <span class="dialog-footer">
          <el-button @click="hide_acp" icon="close">取消</el-button>
          <el-button type="primary" @click="save_acp" icon="select">提交</el-button>
        </span>
      </template>
    </el-dialog>
    <el-dialog
      v-model="conf.acq_visible"
      title="完成"
      :close-on-click-modal="false"
      width="60%"
      draggable
      :before-close="hide_acq"
    >
      <el-form
        :model="form_acq"
        
        ref="fm_acq"
        :rules="rules_acq"
      >
  <el-row>
</el-row>
      </el-form>
      <template #footer>
        <span class="dialog-footer">
          <el-button @click="hide_acq" icon="close">取消</el-button>
          <el-button type="primary" @click="save_acq" icon="select">提交</el-button>
        </span>
      </template>
    </el-dialog>
  </div>
</template>

<script>
export default {
  data(){
    return{
      conf:{
        acp_visible:false,
        acq_visible:false,
      },
      //待复评 form by  pt
    form_acp:{},
      //完成 form by  pt
    form_acq:{},
    rules_acp:{
        },
    rules_acq:{
        },
    }
  },
  methods:{
     //--------------------待复评---------------------------------
      //显示 待复评 弹出框 {"Tag":"DIALOG","Name":"CMPNT","Cmd":"batupdator","Label":"待复评","Desc":"待复评","ICON":"right","URL":"@/views/{@prefix}/{@main}/{@name}.dialog","RwName":"pt","FwName":"tm","ReqURL":"waitfp","IsMux":true,"Table":"ws_project_design","Params":{"@pd_id":"\u0026bcheck","@pdstatus":"30","fwName":"tm","icon":"right","idx":"2","rwName":"pt"},"ParentUNQ":"","UNQ":"acp"}
      show_acp(fm){
          
        //处理关联表@/views/{@prefix}/{@main}/{@name}.dialog
        let currentForm = {}

         Object.assign(this.form_acp,currentForm)
         Object.assign(this.form_acp,fm)
         this.conf.acp_visible = true;
      },
      //隐藏 待复评 弹出框
      hide_acp(){
        this.conf.acp_visible = false;
        this.$refs.fm_acp.resetFields();
      },
      //保存 待复评 弹出框数据
      save_acp(){
        let that = this
        this.$refs.fm_acp.validate((v=>{
            if(!v){
                return
            }
        let post_form_acp = this.form_acp
        
        this.$theia.http.post("/ws/project/design/waitfp",post_form_acp).then(res=>{
            that.$notify.success({title: '成功',message: '提交成功',duration:5000})
            that.$emit("onsaved")
            that.hide_acp()
            
        }).catch(res=>{
          let code = ((res||{}).response||{}).status||0
          let msg= `提交失败(${code})`
          that.$notify.error({title: '失败',message:msg,duration:5000})
        })
        }))
    },
    //-----------------------------------------------------------
     //--------------------完成---------------------------------
      //显示 完成 弹出框 {"Tag":"DIALOG","Name":"CMPNT","Cmd":"batupdator","Label":"完成","Desc":"完成","ICON":"right","URL":"@/views/{@prefix}/{@main}/{@name}.dialog","RwName":"pt","FwName":"tm","ReqURL":"waitfp","IsMux":true,"Table":"ws_project_design","Params":{"@pd_id":"\u0026bcheck","@pdstatus":"0","fwName":"tm","icon":"right","idx":"2","rwName":"pt"},"ParentUNQ":"","UNQ":"acq"}
      show_acq(fm){
          
        //处理关联表@/views/{@prefix}/{@main}/{@name}.dialog
        let currentForm = {}

         Object.assign(this.form_acq,currentForm)
         Object.assign(this.form_acq,fm)
         this.conf.acq_visible = true;
      },
      //隐藏 完成 弹出框
      hide_acq(){
        this.conf.acq_visible = false;
        this.$refs.fm_acq.resetFields();
      },
      //保存 完成 弹出框数据
      save_acq(){
        let that = this
        this.$refs.fm_acq.validate((v=>{
            if(!v){
                return
            }
        let post_form_acq = this.form_acq
        
        this.$theia.http.post("/ws/project/design/waitfp",post_form_acq).then(res=>{
            that.$notify.success({title: '成功',message: '提交成功',duration:5000})
            that.$emit("onsaved")
            that.hide_acq()
            
        }).catch(res=>{
          let code = ((res||{}).response||{}).status||0
          let msg= `提交失败(${code})`
          that.$notify.error({title: '失败',message:msg,duration:5000})
        })
        }))
    },
    //-----------------------------------------------------------
  },
}
</script>
<style scoped>
.form_item_info{
  margin-left: 4px;
  color:#999;
}
.form_item_info:hover{
  cursor: pointer;
  font-weight: 500;
  color:#333;
}
</style>